\documentclass{standalone}
\usepackage{tikz}
\usepackage{ctex,siunitx}
\setCJKmainfont{Noto Serif CJK SC}
\usepackage{tkz-euclide}
\usepackage{amsmath}
\usepackage{wasysym}
\usepackage{circuitikz}
\usetikzlibrary{patterns, calc}
\usetikzlibrary {decorations.pathmorphing, decorations.pathreplacing, decorations.shapes,}
\begin{document}
\small
\begin{circuitikz}[>=latex, scale=1.0,european]
  \useasboundingbox(0,1)rectangle(5,-2.4);
  \draw (0,0) to [R] (5,0);
  \node at (2-.3,0)[above]{$+$};\node at (3+.3,0)[above]{$-$};
  \draw (2.5,-.18)--(2.5,.18);
  \node at (2.2,0){P};\node at (2.8,0){N};
  \draw (0,-1) to [empty diode, fill=black] (5,-1);   
  \node at (2,-1)[above]{$+$};\node at (3,-1)[above]{$-$};
\end{circuitikz}
\end{document}